#include <stdio.h>
#include <stdlib.h>
#include <sys/resource.h>
#include <unistd.h>
#include "tlpi.h"

int
main(int argc, char *argv[])
{
	int nice;
	nice = getpriority(PRIO_PROCESS, 0);
	printf("at first, nice val of proces[%ld]: %d\n", (long)getpid(), nice);
	if(setpriority(PRIO_PROCESS, 0, 100) == -1)
		errExit("setpriority() to 10 failed");

	nice = getpriority(PRIO_PROCESS, 0);
	printf("after, nice val of proces[%ld]: %d\n", (long)getpid(), nice);
	exit(EXIT_SUCCESS);
}

